package com.mofang.ticketing.user.mapping.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * 角色权限
 * @TableName sys_role_permission
 */
@NoArgsConstructor
@AllArgsConstructor
@TableName(value ="sys_role_permission")
@Data
public class SysRolePermissionDO implements Serializable {
    /**
     * 主键ID;主键自增
     */
    @TableId(value = "id")
    private Long id;

    /**
     * 角色ID
     */
    @TableField(value = "role_id")
    private Long roleId;

    /**
     * 权限ID
     */
    @TableField(value = "per_id")
    private Long perId;

    public SysRolePermissionDO(Long roleId, Long perId) {
        this.roleId = roleId;
        this.perId = perId;
    }
}